package com.example.minademo.dao;

import com.example.minademo.entity.Controller;
import org.springframework.data.jpa.repository.JpaRepository;

import java.util.List;

public interface ControllerDao  extends JpaRepository<Controller,Integer> {

    List<Controller> findAllByUserId(Integer id);

    Controller save(Controller controller);

    Controller findByUserIdAndControlledUserId(Integer userId,Integer controlledUserId);

}
